.loan-calculator {
    display: flex;
    flex-wrap: wrap; /* Allow elements to wrap on smaller screens */
    background: linear-gradient(45deg, #5e0875, #9c0d47);
    padding: 40px;
    border-radius: 20px;
    color: #ffffff;
    font-family: Arial, sans-serif;
    gap: 40px;
    width: 100%; /* Ensures the container takes up full width */
    box-sizing: border-box; /* Ensure padding is included in width calculation */
}

.calculator-left, .calculator-right {
    width: 47%;
    box-sizing: border-box;
}

label {
    display: block;
    margin: 10px 0 5px;
    font-weight: bold;
}

.calculator-left p {
    display: flex; /* Enable flexbox for the <p> tag */
    justify-content: space-between; /* Space out the text and span, pushing the span to the right */
    align-items: center; /* Ensure content is vertically aligned */
}

.calculator-left p span {
    margin-left: auto; /* Push span elements to the right */
}



input[type="number"],
input[type="tel"],
input[type="email"],
input[type="text"],
input[type="range"] {
    width: 100%;
    padding: 15px;
    margin-bottom: 10px;
    border-radius: 5px;
    border: none;
    background: #e9e9e9;
    box-sizing: border-box;
    max-width: 100%; /* Ensure inputs do not exceed the container's width */
}

input[type="range"] {
    -webkit-appearance: none;
    height: 5px;
    background: #f3a83b;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 15px;
    height: 15px;
    background: #ff7b00;
    border-radius: 50%;
    cursor: pointer;
}

button[type="submit"], button[type="button"] {
    background: #f3a83b;
    color: #ffffff;
    border: none;
    padding: 15px 55px;
    border-radius: 23px;
    font-weight: bold;
    font-size: 18px;
    cursor: pointer;
    transition: background 0.3s ease;
    margin-left: auto;
    margin-right: auto;
}

button[type="submit"]:hover {
    background: #ff7b00;
}

p {
    font-size: 0.9em;
}

p span {
    font-weight: bold;
}

.loan-calculator h2 {
    font-size: 1.8em;
    color: #f3a83b;
    font-family: Arial, sans-serif;
    margin-bottom: 20px;
}

.slider-container {
    padding: 0px;
    border-radius: 10px;
    width: 350px;
    color: white;
    font-family: Arial, sans-serif;
}

.slider-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
}

.slider-header h2 {
    color: #ffa726;
    font-size: 16px;
    margin: 0;
}

.slider-track-container {
    position: relative;
    padding-top: 10px;
    padding-bottom: 30px;
}

/* Main track */
.slider-track {
    width: 100%;
    height: 2px;
    background-color: rgba(255, 255, 255, 0.2);
    position: relative;
}

/* Tick marks container */
.tick-marks {
    position: relative;
    display: flex;
    justify-content: space-between;
    padding: 0 0px;
    margin-top: -7px;
}

/* Individual tick mark */
.tick {
    width: 2px;
    height: 10px;
    background-color: rgba(255, 255, 255, 0.2);
    position: relative;
}

.tick-label {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
}

/*************************************************************************/

.loan-duration-slider-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #fff; /* White text color for the labels */
    font-family: Arial, sans-serif;
}

.loan-duration-slider-container label {
    font-size: 1.2em;
    margin-bottom: 8px;
    color: #ffa300; /* Orange text color for the label */
}

#loan_duration {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    max-width: 350px; /* Adjust width to fit the container */
    background: linear-gradient(to right, #ffa300, #ff4d6d);
    height: 8px;
    border-radius: 5px;
    outline: none;
    margin-top: 10px;
    margin-bottom: 10px;
}

#loan_duration::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    background-color: #fff;
    border-radius: 50%;
    cursor: pointer;
}

#loan_duration::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background-color: #fff;
    border-radius: 50%;
    cursor: pointer;
}

.slider-labels {
    display: flex;
    justify-content: space-between;
    width: 100%;
    max-width: 350px;
}

.slider-labels span {
    font-size: 0.9em;
    color: #ffa300; /* Color for each week label */
}

.layout-constrained.wp-block-post-content-is-layout-constrained {
    display: flex;
}

span#total_repayment, span#amount_received, span#interest {
    color: #f3a83b;
}

.calculator-left p {
    border-bottom: 1px solid;
}

.borrowing_container {
    display: inline-flex;
}

input#loan_amount {
    width: 276px;
    margin-left: 20px;
}

/* Mobile and tablet responsiveness */
@media (max-width: 1024px) {
    .loan-calculator {
        flex-direction: column;
        padding: 30px;
        gap: 30px;
    }

    .calculator-left, .calculator-right {
        width: 100%;
        margin-bottom: 20px;
    }

    button[type="submit"] {
        margin-left: 0;
        margin-top: 20px;
        width: 100%;
        padding: 12px 0;
    }

    .slider-labels {
        width: 100%;
    }

    .borrowing_container {
        display: block;
        width: 100%;
    }

    input#loan_amount {
        width: 100%;
    }

    .slider-container {
        width: 100%;
        max-width: 100%;
    }
}

@media (max-width: 768px) {
    .loan-calculator {
        padding: 20px;
        gap: 20px;
    }

    .calculator-left, .calculator-right {
        width: 100%;
    }

    .slider-header {
        flex-direction: column;
        align-items: center;
        margin-bottom: 10px;
    }

    button[type="submit"] {
        margin-left: 0;
        width: 100%;
        padding: 12px 0;
    }

    .borrow-input-container {
        width: 100%;
        margin-left: 0;
    }

    input#loan_amount {
        width: 100%;
        margin: 0px;
    }
}

@media (max-width: 448px) {
    .loan-calculator {
        padding: 15px;
        gap: 15px;
    }

    .calculator-left, .calculator-right {
        width: 100%;
        margin-bottom: 15px;
    }

    button[type="submit"] {
        margin-left: 0;
        width: 100%;
        padding: 12px 0;
    }

    input[type="number"],
    input[type="tel"],
    input[type="email"],
    input[type="text"] {
        padding: 10px;
        font-size: 14px; /* Adjust input font size for small screens */
    }

    .slider-container {
        width: 100%;
        max-width: 100%;
    }

    .slider-labels {
        width: 100%;
    }

    .borrowing_container {
        display: block;
        width: 100%;
    }

    input#loan_amount {
        width: 100%;
    }

    p {
        font-size: 0.8em;
    }

    .loan-calculator h2 {
        font-size: 1.4em;
    }

    .loan-duration-slider-container label {
        font-size: 1em;
    }
}

/* Multi-step form styles */
.form-step {
    display: none;
    width: 100%;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s ease-in-out;
}

.form-step.active {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
    opacity: 1;
    transform: translateX(0);
}

/* Form navigation */
.form-navigation {
    width: 40%;
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-left: auto;
    margin-right: auto;
}

.btn-back,
.btn-proceed,
.btn-submit {
    background: #f3a83b;
    color: #ffffff;
    border: none;
    padding: 15px 55px;
    border-radius: 23px;
    font-weight: bold;
    font-size: 18px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.btn-back:hover,
.btn-proceed:hover,
.btn-submit:hover {
    background: #ff7b00;
}

/* Progress dots */
.form-progress {
    width: 100%;
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 30px;
    position: relative;
}

.progress-dot {
    width: 12px;
    height: 12px;
    background-color: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transition: all 0.3s ease;
    position: relative;
}



.progress-dot:last-child::before {
    display: none;
}

.progress-dot.active {
    background-color: #f3a83b;
    transform: scale(1.2);
}




.progress-dot.active::after {
    color: #f3a83b;
}

/* Confirmation step */
.confirmation {
    text-align: center;
    padding: 40px;
    max-width: 600px;
    margin: 0 auto;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 300px;
}

.success-image {
    width: 120px;
    height: auto;
    margin-bottom: 25px;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.confirmation h2 {
    color: #f3a83b;
    font-size: 32px;
    margin-bottom: 25px;
    font-style: italic;
}

.confirmation p {
    color: #f3a83b;
    font-size: 20px;
    line-height: 1.6;
    margin-bottom: 20px;
}

.confirmation p:last-child {
    color: #f3a83b;
    font-weight: bold;
    margin-top: 35px;
    font-size: 22px;
}

/* Additional form field styles */
select {
    width: 100%;
    padding: 15px;
    margin-bottom: 10px;
    border-radius: 5px;
    border: none;
    background: #e9e9e9;
    box-sizing: border-box;
}

input[type="date"] {
    width: 100%;
    padding: 15px;
    margin-bottom: 10px;
    border-radius: 5px;
    border: none;
    background: #e9e9e9;
    box-sizing: border-box;
}

/* Form validation styles */
.error {
    border: 2px solid #ff4646 !important;
}

.error:focus {
    outline-color: #ff4646;
}

/* Form field styles */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #ffffff;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 12px;
    border-radius: 5px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #f3a83b;
    
}

div#step4 {
    gap: 0px;
}

/* Step 1 specific navigation */
.step1-nav {
    width: 100%;
    margin-top: auto;
    margin-bottom: 0;
    display: flex;
    justify-content: center;
}

.calculator-right {
   
    border-radius: 10px;
    
    
}

/* Adjusting gap for step 4 */
div#step4 {
    gap: 0px;
}

/*******************************************************************************/




.wp-loan-calculator input {
    padding: 1.1rem 1rem;
    border-radius: 23px !important;
}

.loan-duration-slider-container {
    display: flex;
    flex-flow: wrap;
}

input#loan_duration {
    margin-left: 40px;
    max-width: 24rem;
}

.slider-labels {
    margin-left: 7rem;
    margin-bottom: 3rem;
}

.calculator-left p {
    border-bottom: 1px solid;
    font-size: 1.2rem;
}

.borrowing_container label {
    line-height: 3;
}

.loan-duration-slider-container label {
    font-size: 1em;
    margin-bottom: 8px;
    color: #fff;
}

.overlay-image{
    margin-top: -720px;
}


@media screen and (min-width: 1025px) {
  .overlay-image, .header-gradient {
    background-position-x: -78px !important;
}
}

@media screen and (max-width: 1025px) {
  input#loan_duration {
    margin-left: 0px; 
    max-width: 24rem;
}

.slider-labels {
    margin-left: 1rem;
}
}

/* Add these styles */
.id-verification-section {
    margin-top: 30px;
    padding: 20px;
    border-top: 1px solid #eee;
}

.id-verification-section h3 {
    margin-bottom: 20px;
    color: #333;
}

#id_type {
    width: 100%;
    padding: 8px;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: #e9e9e9;
}

#id_documents {
    width: 100%;
    padding: 10px;
    border: 2px dashed rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.help-text {
    display: block;
    margin-top: 5px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9em;
}

label.required:after {
    content: " *";
    color: red;
}
